package com.tiancheng.onecode.convert;

import com.tiancheng.onecode.entity.MemberOrder;
import com.tiancheng.onecode.entity.MemberSubOrder;
import com.tiancheng.onecode.trade.model.request.order.OpenCreateOrderBaseVO;
import com.tiancheng.onecode.trade.model.request.order.OpenCreateSubOrderVO;
import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import java.util.List;

/**
 * @ClassName OrderConvert
 * @Description 订单转换
 * @Author kellen
 * @Date 2024/12/28 20:45
 */
@Mapper(componentModel = "spring")

public interface OrderConvert {
    OrderConvert INSTANCE = Mappers.getMapper(OrderConvert.class);

    MemberSubOrder convert(OpenCreateSubOrderVO openCreateSubOrderVO);

    List<MemberSubOrder> convert(List<OpenCreateSubOrderVO> openCreateSubOrderVO);

    MemberOrder convert(OpenCreateOrderBaseVO openCreateOrderBaseVO);
}
